-
Notifications
You must be signed in to change notification settings - Fork 569
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PWA + offline #325
PWA + offline #325
Conversation
Looks like we are back in business. You might want to take a look again. New maintainer! |
d1ffd75
to
d70a8f2
Compare
Ah fantastic! Hopefully things pick back up. So far just this change has made it very useful to. Just pin to Home Screen on mobile and can read even with no internet connection :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @geekgonecrazy, thanks for the PR! This seems amazing. I'm not currently using Shori on my mobile/tablet but this will make it very useful when traveling around.
I'm not very proficent in the front-side of things, so my not-very-expert eyes say it's almost good to go. The only thing I didn't like quite much is that we are serving static assets from the service and also fetching them from the outside. It would be good if we serve those all ourselves.
I know there's a lot of room to improve here, but we need to take it one step at a time.
CC: @m-bers as the original contributor for the PWA
} | ||
</script> | ||
<script type="module"> | ||
import 'https://cdn.jsdelivr.net/npm/@pwabuilder/pwaupdate'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we have this living with our other static assets? It seems weird to me that we serve everything bundled withing the binary but this is fetched from an outside service.
@@ -0,0 +1,102 @@ | |||
//This is the service worker with the Advanced caching | |||
|
|||
importScripts('https://storage.googleapis.com/workbox-cdn/releases/5.1.2/workbox-sw.js'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same as before, can we bundle this within shiori?
@@ -49,6 +49,9 @@ func ServeApp(cfg Config) error { | |||
return path.Join(cfg.RootPath, route) | |||
} | |||
|
|||
router.GET(jp("/pwabuilder-sw.js"), hdl.serveFile) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be served from /js/...
as with the other javascript files.
I am just seeing this now--@geekgonecrazy evidently knows more about PWA caching than I do, but I will try to work on the web share target component which was my original aim (offline was just a bonus) and submit that as a separate PR |
Hey @geekgonecrazy 👋 are you still working on this PR? If not I can take a look and make the updates suggested by @fmartingr |
@karlprieb hey my friend! Fancy seeing you here :) I haven't had time to mess with this for a while. I'll add you as contributor on my fork if you want to make more changes. |
Hey @geekgonecrazy, @karlprieb, is this something you are still interested on working on? |
This issue has been automatically marked as stale because it has not had any activity for quite some time. |
Hey @fmartingr I’m still interested in working on this feature, sadly I’m not having the necessary time to do so :( |
Hey @karlprieb, no problem, I will just keep this open then. We all have our things in life :) |
Any updates about the progress? I think this feature is a game changer for the project. |
I started working on PWA separate from this pull request and have a working PWA profile and share target but not offline caching. I would be open to reworking my patches with this PR and finish this feature. |
Please feel free to take what is done here and wrap into own PR 🙏 |
Incorporate go-shiori#325 changes, copy assets to static res dir, add json mime type for manifest.json
No ETA, but I have an MVP working locally in the iOS simulator. Up to the publishing bit now. |
Could it also be used directly from the browser by adding it to home screen/applications without the need of installing an app from the store? |
Good point! Looks like the offline bit will need more testing.
PWA portion works pretty well, but the viewport needs adjusting for newer phones without a home button.
I'll keep at it 🤙
…________________________________
From: Felipe Martin ***@***.***>
Sent: Tuesday, July 4, 2023 5:22:10 AM
To: go-shiori/shiori ***@***.***>
Cc: pythoninthegrass ***@***.***>; Manual ***@***.***>
Subject: Re: [go-shiori/shiori] PWA + offline (PR #325)
No ETA, but I have an MVP working<master...pythoninthegrass:shiori:shiori-mobile> locally in the iOS simulator. Up to the publishing bit<https://docs.pwabuilder.com/#/builder/app-store?id=publishing> now.
Could it also be used directly from the browser by adding it to home screen/applications without the need of installing an app from the store?
—
Reply to this email directly, view it on GitHub<#325 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AA7ILP3WON3RSV77TBSSPJLXOPVFFANCNFSM5NEX5UHQ>.
You are receiving this because you are subscribed to this thread.Message ID: ***@***.***>
|
Incorporate go-shiori#325 changes, copy assets to static res dir, add json mime type for manifest.json
@fmartingr @pythoninthegrass Hi there, thanks for all the contribution and discussion! PWA would bring Shiori to next level to fully replace other bookmark managers (especially the default bookmark managers from Chrome and Safari). May I know if this PR is still active? If so, any context of the current blocker preventing it from being merged? Thanks. |
I can't say myself, there are some people interested in moving this forward but sadly since we do this in our free time I guess is difficult to just sit down and go on with it. I also think this would be a game changer but I'm not that into frontend development (if I were, I would refactor all of it 😂 ) |
@fmartingr hit the nail on the head. I made some progress but with the latest API changes, it became too much of a lift. I'm pretty green at go and frontend isn't my strong suit. My fork is still available and the manifest.json (manifest.webmanifest) is about 2/3 complete according to pwabuilder. Ended up migrating to Omnivore and while it doesn't quite check all the boxes, it suits my needs and has very responsive devs who are actively implementing features I'm interested in. |
That's sad to hear, but understandable :) I may hop on to the task then, while I make the changes to the API. Thanks for putting your time into it anyway, really appreciated. |
You're welcome! It was a good learning experience and appreciate what you've done to make a viable pocket alternative
…________________________________
From: Felipe Martin ***@***.***>
Sent: Sunday, September 10, 2023 2:21:41 AM
To: go-shiori/shiori ***@***.***>
Cc: pythoninthegrass ***@***.***>; Mention ***@***.***>
Subject: Re: [go-shiori/shiori] PWA + offline (PR #325)
@fmartingr<https://github.com/fmartingr> hit the nail on the head. I made some progress but with the latest API changes, it became too much of a lift.
I'm pretty green at go and frontend isn't my strong suit. My fork is still available and the manifest.json (manifest.webmanifest) is about 2/3 complete according to pwabuilder<https://www.pwabuilder.com/>.
Ended up migrating to Omnivore and while it doesn't quite check all the boxes, it suits my needs and has very responsive devs who are actively implementing features I'm interested in.
That's sad to hear, but understandable :)
I may hop on to the task then, while I make the changes to the API. Thanks for putting your time into it anyway, really appreciated.
—
Reply to this email directly, view it on GitHub<#325 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AA7ILP5VFYRAFI7PYCBZ5BDXZVTALANCNFSM5NEX5UHQ>.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
Any helper needed ? I wanted to make a simple pwa of shiori just to be able to share links to it, but apparently some work was done here ? |
Absolutely! The frontend side needs a hand, but if you could bring the PWA to an usable state it would be awesome tbh :) |
Maybe a very dumb question but what is the user/pwd of the dev local dev instance ? I can't find it in the doc |
Lots have changed since the previous devs attempt to add a PWA. I'm trying to from scratch just to add a manifest and I'm a bit confused by the routing system, fonrtend.go seems to says that the assets folder is statically accesible but alas my manifest get 404 |
Yeah, files stored under If you can, submit your PR in draft mode and we can provide assistance in there. |
Allright, posted here : #919 |
This issue has been automatically marked as stale because it has not had any activity for quite some time. |
I know this project seems to be abandoned. But contributing on the off chance that you pick it up. Based on #296 but this makes it work fully disconnected and caches some bookmarks for offline viewing making it more pocket like and useful